package com.example.lotterysystem.controller.result;

import lombok.Data;

import java.io.Serializable;
import java.math.BigDecimal;
import java.util.List;


@Data
/**
 * 该类用于封装查询奖品列表的返回结果，包含奖品总量和当前页的奖品数据。
 */
public class FindPrizeListResult {
    // 奖品总量
    private Integer total;

    //当前页面奖品列表
    private List<PrizeInfo> records;


    public List<PrizeInfo> getRecords() {
        return records;
    }

    public void setRecords(List<PrizeInfo> records) {
        this.records = records;
    }

    public Integer getTotal() {
        return total;
    }

    public void setTotal(Integer total) {
        this.total = total;
    }

    @Data
    public static class PrizeInfo implements Serializable{
        //奖品ID
        private Long prizeId;
        //奖品名称
        private String prizeName;
        //奖品描述
        private String description;
        //奖品价格
        private BigDecimal price;
        //奖品图片
        private String imageUrl;

        public Long getPrizeId() {
            return prizeId;
        }

        public void setPrizeId(Long prizeId) {
            this.prizeId = prizeId;
        }

        public String getPrizeName() {
            return prizeName;
        }

        public void setPrizeName(String prizeName) {
            this.prizeName = prizeName;
        }

        public String getDescription() {
            return description;
        }

        public void setDescription(String description) {
            this.description = description;
        }

        public String getImageUrl() {
            return imageUrl;
        }

        public void setImageUrl(String imageUrl) {
            this.imageUrl = imageUrl;
        }

        public BigDecimal getPrice() {
            return price;
        }

        public void setPrice(BigDecimal price) {
            this.price = price;
        }
    }
}
